C From http://www.osc.edu/supercomputing/training/mpi/mpi_0504.pdf   
  INTEGER I, position
  REAL a(200)
  CHARACTER buff(2000)
  …
  CALL MPI_TYPE_SIZE(MPI_CHARACTER, size, ierr)
  size = 2000*size
  position = 0
  IF (myrank .EQ. 0) THEN
    i=25
    CALL MPI_PACK( I, 1, MPI_INTEGER, buff, size, position, MP_COMM_WORLS, ierr)
    CALL MPI_PACK( a, i, MPI_REAL, buff, size, position, MP_COMM_WORLS, ierr)
    CALL MPI_SEND( buff, position, MPI_PACKED, 1,99, MPI_COMM_WORLS, ierr)
  ELSE
    CALL MPI_RECV( buff, size, MPI_PACKED, 0, 99, MPI_COMM_WORLD, status, ierr)
    CALL MPI_UNPACK( buff, size, position, i, 1, MPI_INTEGER, MP_COMM_WORLS, ierr)
    CALL MPI_UNPACK( buff, size, position, a, i, MPI_INTEGER, MP_COMM_WORLS, ierr)
  ENDIF
